﻿using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace TXTD.Admin.Data.Migrations
{
    public partial class _202207162 : Migration
    {
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.CreateIndex(
                name: "IX_SYS_DICTIONARY_ITEMS_DICTIONARY_ID",
                table: "SYS_DICTIONARY_ITEMS",
                column: "DICTIONARY_ID");

            migrationBuilder.AddForeignKey(
                name: "FK_SYS_DICTIONARY_ITEMS_SYS_DICTIONARY_DICTIONARY_ID",
                table: "SYS_DICTIONARY_ITEMS",
                column: "DICTIONARY_ID",
                principalTable: "SYS_DICTIONARY",
                principalColumn: "DICTIONARY_ID",
                onDelete: ReferentialAction.Cascade);
        }

        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropForeignKey(
                name: "FK_SYS_DICTIONARY_ITEMS_SYS_DICTIONARY_DICTIONARY_ID",
                table: "SYS_DICTIONARY_ITEMS");

            migrationBuilder.DropIndex(
                name: "IX_SYS_DICTIONARY_ITEMS_DICTIONARY_ID",
                table: "SYS_DICTIONARY_ITEMS");
        }
    }
}
